Scenario #5002: Unsubscribe Person and Contact From Mailinglist

Properties

Required

Given

name value
mailingList operations-announce
subscriberEMailAddress michael.miller@example.org

Subscription: michael.miller@example.org

HTTP GET "/api/hs/office/relations?relationType=SUBSCRIBER&mark=operations-announce&contactData=michael.miller%40example.org" \
  -H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
  `# {` \
  `#   "sub" : "uuid<hsh-alex_superuser>"` \
  `# }`
=> status: 200 OK 
[ {
  "uuid" : "fe03bdee-212a-49c6-a2b9-362362610e09", // Subscription: Michael Miller to operations-announce
  "anchor" : {
    "uuid" : "3029ef4b-ab91-429d-855b-26a8bedcef6e", // Person: Test AG
    "personType" : "LEGAL_PERSON",
    "tradeName" : "Test AG",
    "salutation" : null,
    "title" : null,
    "givenName" : null,
    "familyName" : null
  },
  "holder" : {
    "uuid" : "4023f949-de5c-4708-b1fa-fddbfacab1c7", // Person: Michael Miller
    "personType" : "NATURAL_PERSON",
    "tradeName" : null,
    "salutation" : null,
    "title" : null,
    "givenName" : "Michael",
    "familyName" : "Miller"
  },
  "type" : "SUBSCRIBER",
  "mark" : "operations-announce",
  "contact" : {
    "uuid" : "a333a58f-f2ce-454b-9d86-b26d31f7d700", // Contact: michael.miller@example.org
    "caption" : "Michael Miller",
    "postalAddress" : { },
    "emailAddresses" : {
      "main" : "michael.miller@example.org"
    },
    "phoneNumbers" : { }
  }
} ]

In production, data this query could result in multiple outputs. In that case, you have to find out which is the right one.

Delete the Subscriber-Relation by its UUID

HTTP DELETE "/api/hs/office/relations/fe03bdee-212a-49c6-a2b9-362362610e09" // Subscription: michael.miller@example.org \
  -H "Authorization: Bearer $HSADMINNG_JWT_BEARER" \
  `# {` \
  `#   "sub" : "uuid<hsh-alex_superuser>"` \
  `# }`
=> status: 204 NO_CONTENT 

generated on 2026-08-10 03:08:33 for branch HEAD